package com.jeesite.modules.mo.entity;

import javax.validation.constraints.Size;
import java.util.Date;
import com.jeesite.common.mybatis.annotation.JoinTable;
import com.jeesite.common.mybatis.annotation.JoinTable.Type;
import com.fasterxml.jackson.annotation.JsonFormat;

import com.jeesite.common.entity.DataEntity;
import com.jeesite.common.mybatis.annotation.Column;
import com.jeesite.common.mybatis.annotation.Table;
import com.jeesite.common.mybatis.mapper.query.QueryType;
import com.jeesite.modules.ic.entity.IcUser;

/**
 * 退款Entity
 * @author 李寒冰
 * @version 2025-02-18
 */
@Table(name="mo_refund", alias="a", label="退款信息", columns={
		@Column(name="id", attrName="id", label="id", isPK=true),
		@Column(name="user_id", attrName="userId", label="用户ID"),
		@Column(name="jine", attrName="jine", label="金额", isUpdateForce=true),
		@Column(name="create_time", attrName="createTime", label="时间", isUpdateForce=true),
		@Column(name="type", attrName="type", label="1 任务退款"),
	}, orderBy="a.id DESC"
)
public class MoRefund extends DataEntity<MoRefund> {
	
	private static final long serialVersionUID = 1L;
	private String userId;		// 用户ID
	private Double jine;		// 金额
	private Date createTime;		// 时间
	private String type;		// 1 任务退款
	private IcUser icUser;

	public IcUser getIcUser() {
		return icUser;
	}

	public void setIcUser(IcUser icUser) {
		this.icUser = icUser;
	}

	public MoRefund() {
		this(null);
	}
	
	public MoRefund(String id){
		super(id);
	}
	
	@Size(min=0, max=50, message="用户ID长度不能超过 50 个字符")
	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}
	
	public Double getJine() {
		return jine;
	}

	public void setJine(Double jine) {
		this.jine = jine;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	
	@Size(min=0, max=255, message="1 任务退款长度不能超过 255 个字符")
	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}
	
}